extends Object

const ObjectEx = preload("ObjectEx.gd")
const ArrayEx = preload("ArrayEx.gd")

static func isEmpty(s: String) -> bool:
	return ObjectEx.isNull(s) or s.is_empty()

static func isBlank(s: String) -> bool:
	if ObjectEx.isNull(s) || s.strip_edges(true, true).is_empty():
		return true
	return false

static func format(s: String, values: Array, placeholder: String = "{}") -> String:
	if isEmpty(s) || ArrayEx.isEmpty(values):
		return s
	return s.format(values, placeholder)
